#include <iostream>
#include <cstdio>
#include <iterator>
#include <algorithm>
#include <string>
#include <vector>
#include "tinyxml.h"

using namespace std;

struct PathInfo
{
	string sTagName;
	int count;
};

struct TimeSchedule
{
	string sStartTime;
	string sEndTime;
	int nInterval;
	int next;
};

struct LotteryInfo
{
	string sName;
	vector<TimeSchedule> vTimeShedules;
	vector<PathInfo> vPaths;
};

struct LotteryResult
{
	string sNumber;
	string sResult;
};

vector<PathInfo> parseXpathInfo(TiXmlElement* pXpathRoot);
vector<LotteryInfo> parseConfigFile(string sConfigFile);
vector<LotteryResult> parseLotteryResult(string sXmlString, LotteryInfo& rLotteryInfo);

